import request from '@/utils/axios'

export type NotifyRecordType = {
  id: number
  userId: number
  userType: number
  templateId: number
  templateCode: string
  templateNickname: string
  templateContent: string
  templateType: number
  templateParams: string
  readStatus: boolean
  readTime: Date
  create_time?: Date
}

export interface NotifyRecordPageReqType extends PageParam {
  userType?: number
  userId?: number
  templateCode?: string
  templateType?: number
  create_time?: Date[]
}

/**
 * 消息中心 - 站内信管理 - 站内信消息记录接口
 */
export const NotifyRecordApi = {
  // 查询分页列表
  page: (params: NotifyRecordPageReqType) => {
    return request.get({ url: '/system/notify-record/page', params, is_mock: true })
  }
}
